<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>登陆</title>
    <link href="css/login.css" rel="stylesheet">
</head>
<body>
<div id="loginDiv">
    <form action="loginServlet" method="post" id="form">
        <h1 id="loginMsg">登陆界面</h1>
        <div id="errorMsg" style="height: 25px;">${login_msg} ${register_msg}</div>
        <table>
            <tbody>
            <tr>
                <th>用户名：</th>
                <th><input id="username" name="username" type="text" value="${cookie.username.value}"></th>
            </tr>
            <tr>
                <th>密&nbsp;&nbsp;&nbsp;码：</th>
                <th><input id="password" name="password" type="password" value="${cookie.password.value}"></th>
            </tr>
            <tr>
                <th>记住我：</th>
                <th>
                    <input id="remember" name="remember" type="checkbox" value="1" <c:if test="${cookie.username.value != ''}">checked</c:if>>
                </th>
            </tr>
            </tbody>
        </table>
        <div id="subDiv">
            <input type="submit" class="button" value="登陆">
            <input type="reset" class="button" value="重置">
        </div>
        <p><a href="register.jsp">没有账号？点击注册</a></p>
    </form>
</div>
</body>
</html>